﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;

using _XNA__RunningDeath.GLO;

namespace _XNA__RunningDeath.GUI
{
    class CGUI_SaveGame:CDiaLogBox
    {
        Texture2D _texBackground;
        Texture2D _texBtnBack;
        Texture2D _texBtnSave;

        public CGUI_SaveGame(ContentManager content,GameTime gameTime,SpriteBatch spriteBatch):base(content,gameTime,spriteBatch)
        {
            this._texBackground = this._content.Load<Texture2D>(@"GUI/bgSaveGame");
            this._texBtnBack = this._content.Load<Texture2D>(@"GUI/btnBack");
            this._texBtnSave = this._content.Load<Texture2D>(@"GUI/btnSave");
            this._texBG = this._content.Load<Texture2D>(@"GUI/guiBG");
            this._dstoado = this._content.Load<Dictionary<string, Rectangle>>(@"GUI/ztoadoXMLgui");
        }
        public override void Update(GameTime gameTime)
        {
            CGLOBAL.MousePrev = CGLOBAL.MouseCurrent;
            CGLOBAL.MouseCurrent = Mouse.GetState();
           // if (CGLOBAL.MouseCurrent.LeftButton == ButtonState.Pressed && CGLOBAL.MousePrev.LeftButton == ButtonState.Pressed)
        }
        public override void Draw(GameTime gameTime)
        {
            this._spriteBatch.Begin();
            this._spriteBatch.Draw(this._texBG, Vector2.Zero, Color.Gray);
            this._spriteBatch.Draw(this._texBackground, new Vector2(this._dstoado["bgSaveGame"].X, this._dstoado["bgSaveGame"].Y), Color.White);
            this._spriteBatch.Draw(this._texBtnBack, new Vector2(this._dstoado["btnBackSaveGame"].X, this._dstoado["btnBackSaveGame"].Y), Color.White);
            this._spriteBatch.Draw(this._texBtnSave, new Vector2(this._dstoado["btnSaveGame"].X, this._dstoado["btnSaveGame"].Y), Color.White);
            this._spriteBatch.End();
        }
    }
}
